<template>
  <div class="page">
    <el-pagination
      @size-change="handleSizeChange"
      @current-change="handleCurrentChange"
      :current-page="currentPage"
      :page-sizes="[2, 10, 20, 30]"
      layout="total, sizes, prev, pager, next, jumper"
      :total="total"
    >
    </el-pagination>
  </div>
</template>

<script>
export default {
  name: "PageView",
  props: ["tableData", "total"],
  methods: {
    handleSizeChange(val) {
      this.$bus.$emit("changeSize", val);
    },
    handleCurrentChange(val) {
      this.$bus.$emit("changeNum", val);
    },
  },
  data() {
    return {
      currentPage: 1,
    };
  },

  mounted() {},
};
</script>

<style lang="scss" scoped>
.page {
  text-align: left;
}
</style>